/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package com.cadi.games;

import com.cadi.aux.ItemIntermediateSuper;
import javax.swing.ImageIcon;
import javax.swing.JLabel;
import javax.swing.JLayeredPane;

/**
 *
 * @author ApoZuniga
 */
public class IntermediateSuper extends ItemIntermediateSuper {
    private JLabel background;
    private JLabel imageInstruction;
    public IntermediateSuper() {
    }
    
    public IntermediateSuper(int level) {
        super();
        voice = java.applet.Applet.newAudioClip(getClass().getResource("/resources/eligePago.wav"));
        voice.play();
        character.setBounds(5, 440, 149, 300);
        playVoice.setBounds(135, 550, 50, 50);
        imageInstruction = new JLabel(new ImageIcon(getClass().getResource("/resources/globoSuper.png")));
        imageInstruction.setBounds(140, 390, 200, 162);
        this.container.add(imageInstruction, JLayeredPane.PALETTE_LAYER); 
        switch (level) {
            case 1:
                instruction.setText("El total que debes pagar por el aceite es: ");
                requiredTotal.setText("$ 13.00");
                product.setIcon(new ImageIcon(getClass().getResource("/resources/compra2_1.png")));
                total = 13;
                break;
            case 2:
                instruction.setText("El total que debes pagar por el cereal es: ");
                requiredTotal.setText("$ 17.00");
                product.setIcon(new ImageIcon(getClass().getResource("/resources/compra2_2.png")));
                product.setBounds(50, 80, 162, 170);
                total = 17;
                break;
            case 3:
                instruction.setText("El total que debes pagar por las galletas es: ");
                requiredTotal.setText("$ 23.00");
                product.setIcon(new ImageIcon(getClass().getResource("/resources/compra2_3.png")));
                product.setBounds(50, 80, 162, 170);
                total = 23;
                break;
            case 4:
                instruction.setText("El total que debes pagar por el refresco es: ");
                requiredTotal.setText("$ 35");
                product.setIcon(new ImageIcon(getClass().getResource("/resources/compra2_4.png")));
                product.setBounds(50, 80, 162, 170);
                total = 35;
                break;
            case 5:
                instruction.setText("El total que debes pagar por la leche es: ");
                requiredTotal.setText("$ 18");
                product.setIcon(new ImageIcon(getClass().getResource("/resources/compra2_5.png")));
                product.setBounds(50, 80, 162, 170);
                total = 18;
                break;
            case 6:
                instruction.setText("El total que debes pagar por los productos es: ");
                requiredTotal.setText("$ 49");
                product.setIcon(new ImageIcon(getClass().getResource("/resources/compra2_6.png")));
                product.setBounds(50, 80, 200, 170);
                total = 49;
                break;
            case 7:
                instruction.setText("El total que debes pagar por los productos es: ");
                requiredTotal.setText("$ 67");
                product.setIcon(new ImageIcon(getClass().getResource("/resources/compra2_7.png")));
                product.setBounds(50, 80, 200, 170);
                total = 67;
                break;
        }
        
        background = new JLabel(new ImageIcon(getClass().getResource("/resources/fondo4.png")));
        background.setBounds(0, 0, 1280,800);
        container.add(background, JLayeredPane.PALETTE_LAYER);
        window.repaint();
        
    }
    
}
